import request from '@/utils/request'
import {getToken} from '@/utils/auth'
var token = getToken()
//列表
export function getRegionList() {
  return request({
    url: '/region/list',
    method: 'get',
  })
}
//分页列表
export function getRegionPageList(data,pageData) {
  return request({
    url: '/region/page/'+pageData.pageNo+'/'+pageData.pageSize,
    method: 'post',
    headers:{'Content-Type':'application/json'},
    data
  })
}

//新增
export function getRegionAdd(data) {
    return request({
      url: '/region/add',
      method: 'post',
      data
    })
  }

// 修改
export function getRegionUpdate(data) {
    return request({
      url: '/region/update',
      method: 'post',
      data
    })
  }


// 查看
export function getRegionDetail(id) {
    return request({
      url: '/region/detail/'+id,
      method: 'get',
    })
  }

// 删除
export function getRegionDelete(id) {
    return request({
      url: '/region/delete/'+id,
      method: 'get',
    })
  }

  //项目编辑
  export function getServicesAdd(data){
    return request({
      url: '/services/items/add',
      method: 'post',
      data
    })
  }

  //项目详情

  export function getServicesDetail(data) {
    return request({
      url: '/services/items/detail',
      method: 'post',
      data
    })
  }
  export function getNameList(data) {
    return request({
      url: '/services/items/name',
      method: 'post',
      data
    })
  }
